﻿import kliment.effect.text.TextAbstract;

/**
 * ...
 * @author	Kliment
 * @version	1.1.0
 */
class kliment.effect.text.TextType extends TextAbstract {
	
	public function TextType(text:String, target_tf:TextField, suffix:String) {
		super(text, target_tf, suffix);
	}
	
	private function _render():Void {
		_i++;
		if (_lenght + _suffixLenght >= _i)    {
			_target_tf.text = _text.substr(0, _i) + _suffix;
		} else {
			_target_tf.text = _text;
			_harakiri();
		}
	}
	
}